<?php

class DB
{
    private static $obj=null;
//TODO
    private function __construct()
    {

    }
    static  function getObj(){

        if( is_null(self::$obj)){
            self::$obj=new DB();
        }
        return self::$obj;
        //TODO
    }
}

var _dump(DB::getObj());
var _dump(DB::getObj());
?>